<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Product_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-product_id" class="form-control" name="row[product_id]" type="number" placeholder="请输入商品ID">
            <span class="help-block">输入商品ID后，系统将自动加载该商品的规格信息</span>
        </div>
    </div>
    
    <!-- 商品信息显示区域 -->
    <div id="product-info" class="form-group" style="display: none;">
        <label class="control-label col-xs-12 col-sm-2">商品信息:</label>
        <div class="col-xs-12 col-sm-8">
            <div class="alert alert-info">
                <strong id="product-name"></strong>
                <br><small id="product-desc"></small>
            </div>
        </div>
    </div>
    
    <!-- 商品规格列表 -->
    <div id="sku-list" class="form-group" style="display: none;">
        <label class="control-label col-xs-12 col-sm-2">规格设置:</label>
        <div class="col-xs-12 col-sm-8">
            <div class="panel panel-default">
                <div class="panel-heading">
                    <h4 class="panel-title">为每个规格设置权益价格</h4>
                </div>
                <div class="panel-body">
                    <div class="table-responsive">
                        <table class="table table-striped">
                            <thead>
                                <tr>
                                    <th>规格名称</th>
                                    <th>原价</th>
                                    <th>库存</th>
                                    <th>权益价格</th>
                                    <th>状态</th>
                                </tr>
                            </thead>
                            <tbody id="sku-tbody">
                                <!-- 动态生成的规格列表 -->
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>
    </div>
    
    <!-- 兼容旧版本的单价格输入（当没有规格时显示） -->
    <div id="single-price" class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Equity_price')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-equity_price" class="form-control" step="0.01" name="row[equity_price]" type="number" placeholder="请输入权益价格">
        </div>
    </div>
    
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Shelf_status')}:</label>
        <div class="col-xs-12 col-sm-8">
            <select id="c-shelf_status" class="form-control selectpicker" name="row[shelf_status]">
                <option value="1">上架</option>
                <option value="0">下架</option>
            </select>
        </div>
    </div>
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>